Optimal. Leaf size=74 \[ -\frac {c+d x}{2 f (a \tanh (e+f x)+a)}+\frac {(c+d x)^2}{4 a d}-\frac {d}{4 f^2 (a \tanh (e+f x)+a)}+\frac {d x}{4 a f} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.05, antiderivative size = 74, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, integrand size = 18, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {3723, 3479, 8} \[ -\frac {c+d x}{2 f (a \tanh (e+f x)+a)}+\frac {(c+d x)^2}{4 a d}-\frac {d}{4 f^2 (a \tanh (e+f x)+a)}+\frac {d x}{4 a f} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 8
Rule 3479
Rule 3723
Rubi steps
\begin {align*} \int \frac {c+d x}{a+a \tanh (e+f x)} \, dx &=\frac {(c+d x)^2}{4 a d}-\frac {c+d x}{2 f (a+a \tanh (e+f x))}+\frac {d \int \frac {1}{a+a \tanh (e+f x)} \, dx}{2 f}\\ &=\frac {(c+d x)^2}{4 a d}-\frac {d}{4 f^2 (a+a \tanh (e+f x))}-\frac {c+d x}{2 f (a+a \tanh (e+f x))}+\frac {d \int 1 \, dx}{4 a f}\\ &=\frac {d x}{4 a f}+\frac {(c+d x)^2}{4 a d}-\frac {d}{4 f^2 (a+a \tanh (e+f x))}-\frac {c+d x}{2 f (a+a \tanh (e+f x))}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.31, size = 81, normalized size = 1.09 \[ \frac {\left (2 c f (2 f x+1)+d \left (2 f^2 x^2+2 f x+1\right )\right ) \tanh (e+f x)+2 c f (2 f x-1)+d \left (2 f^2 x^2-2 f x-1\right )}{8 a f^2 (\tanh (e+f x)+1)} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.42, size = 101, normalized size = 1.36 \[ \frac {{\left (2 \, d f^{2} x^{2} - 2 \, c f + 2 \, {\left (2 \, c f^{2} - d f\right )} x - d\right )} \cosh \left (f x + e\right ) + {\left (2 \, d f^{2} x^{2} + 2 \, c f + 2 \, {\left (2 \, c f^{2} + d f\right )} x + d\right )} \sinh \left (f x + e\right )}{8 \, {\left (a f^{2} \cosh \left (f x + e\right ) + a f^{2} \sinh \left (f x + e\right )\right )}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.16, size = 67, normalized size = 0.91 \[ \frac {{\left (2 \, d f^{2} x^{2} e^{\left (2 \, f x + 2 \, e\right )} + 4 \, c f^{2} x e^{\left (2 \, f x + 2 \, e\right )} - 2 \, d f x - 2 \, c f - d\right )} e^{\left (-2 \, f x - 2 \, e\right )}}{8 \, a f^{2}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [B] time = 0.16, size = 165, normalized size = 2.23 \[ \frac {-d \left (\frac {\left (f x +e \right ) \left (\cosh ^{2}\left (f x +e \right )\right )}{2}-\frac {\cosh \left (f x +e \right ) \sinh \left (f x +e \right )}{4}-\frac {f x}{4}-\frac {e}{4}\right )-\frac {\left (\cosh ^{2}\left (f x +e \right )\right ) c f}{2}+\frac {\left (\cosh ^{2}\left (f x +e \right )\right ) d e}{2}+d \left (\frac {\left (f x +e \right ) \cosh \left (f x +e \right ) \sinh \left (f x +e \right )}{2}+\frac {\left (f x +e \right )^{2}}{4}-\frac {\left (\cosh ^{2}\left (f x +e \right )\right )}{4}\right )+c f \left (\frac {\cosh \left (f x +e \right ) \sinh \left (f x +e \right )}{2}+\frac {f x}{2}+\frac {e}{2}\right )-d e \left (\frac {\cosh \left (f x +e \right ) \sinh \left (f x +e \right )}{2}+\frac {f x}{2}+\frac {e}{2}\right )}{f^{2} a} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.34, size = 74, normalized size = 1.00 \[ \frac {1}{4} \, c {\left (\frac {2 \, {\left (f x + e\right )}}{a f} - \frac {e^{\left (-2 \, f x - 2 \, e\right )}}{a f}\right )} + \frac {{\left (2 \, f^{2} x^{2} e^{\left (2 \, e\right )} - {\left (2 \, f x + 1\right )} e^{\left (-2 \, f x\right )}\right )} d e^{\left (-2 \, e\right )}}{8 \, a f^{2}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 1.13, size = 76, normalized size = 1.03 \[ \frac {\frac {d\,x^2}{4}+\left (\frac {c}{2}+\frac {d}{4\,f}\right )\,x}{a}-\frac {\frac {\frac {d}{4}+\frac {c\,f}{2}}{f^2}-x\,\left (\frac {c}{2}-\frac {d}{4\,f}\right )+x\,\left (\frac {c}{2}+\frac {d}{4\,f}\right )}{a+a\,\mathrm {tanh}\left (e+f\,x\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ \frac {\int \frac {c}{\tanh {\left (e + f x \right )} + 1}\, dx + \int \frac {d x}{\tanh {\left (e + f x \right )} + 1}\, dx}{a} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________